package com.xiaoxi.abstractfactorymode.listfactory;

import com.xiaoxi.abstractfactorymode.factory.ILink;

/**
 * @ClassName Link
 * @Description url 标签
 * @Author xiaoxi
 * @Date 2023/3/12 21:19
 * @Version 1.0
 */
public class ListLink extends ILink {

    public ListLink(String caption, String url) {
        super(caption, url);
    }

    @Override
    public String makeHTML() {
        String str = "<li><a href=\"%s\">%s</a></li>\n";
        return String.format(str, url, caption);
    }
}
